<%@ page language="java" contentType="text/html; charset=utf-8"
	pageEncoding="utf-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://www.springframework.org/tags" prefix="spring"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%>
<%@page isELIgnored="false"%>
<!DOCTYPE html>
<html>

<head>
<meta charset="utf-8" />
<c:set var="title" value="酒店信息" scope="request" />
<jsp:include page="/head.jsp" />
</head>

<body>
	<c:import url="/header.do?full=1" />
	<div class="col-md-2">
		<c:import url="/left-menu.do" />
	</div>
	<div class="col-md-10 news-add">
		<ol class="breadcrumb">
			<li><a href="user.html">酒店管理</a></li>
			<li class="active">酒店信息</li>
		</ol>

		<form enctype="multipart/form-data" class="form-horizontal" action="/hotelInfo-update.html"
			method="post" >
			<div class="col-md-12">
				<div class="main-title">
					<div>店 铺 基 本 信 息</div>
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-2 control-label">店铺类型</label>
				<div class="col-sm-4">
					<input type="text" class="form-control" name="shopTypeName"
						value="${shopTypeName }" readonly="readonly" />
				</div>
				<label class="col-sm-2 control-label">店铺名称</label>
				<div class="col-sm-4">
					<input required="required" type="text" class="form-control"
						name="shopName" value="${shopInfo.shopName }" />
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-2 control-label">店铺说明</label>
				<div class="col-sm-10">
					<textarea name="shopMemo" class="form-control" style="height: 8em;">${shopInfo.shopMemo }</textarea>
				</div>
			</div>
			<div class="col-md-12">
				<div class="main-title">
					<div>店 铺 照 片</div>
				</div>
			</div>
			<div id="img" class="col-md-12">
				<img src="${shopInfo.img[0] }" id="show" width="200">
				<script type="text/javascript">
					var str = "";
					$(function() {
						if ("${i }" == null) {
							str += "<input id='file' required='required' name='file' class='filepath btn btn-default' onchange='changepic(this)' type='file'><br>";
						} else {
							str += "<a id='btn1' class='btn btn-default' >修改图片</a>";
						}
						$("#img").append(str);
						var button = document.getElementById("btn1");
						button.onclick = function() {
							str = ""
							str += "<input id='file' required='required' name='imgs' class='filepath btn btn-default' onchange='changepic(this)' type='file'><br>";
							$("#img").append(str);
						}
					});
				</script>
			</div>
			<div style="width: 16%; margin: auto;">
				<button type="submit" class="btn btn-default">提交</button>
			</div>
		</form>


	</div>
	<jsp:include page="/footer.jsp" />

</body>

</html>